package model.model03.demo04.controller;

import com.model.model03.demo04.component.RequestComponent;
import com.model.model03.demo04.decorator.LogDecorator;
import com.model.model03.demo04.decorator.ValidDecorator;

public class UserController {

    public String login() {
        RequestComponent cc = new RequestComponent();

        LogDecorator logD = new LogDecorator();
        ValidDecorator validD = new ValidDecorator();

        validD.setComponent(cc);
        logD.setComponent(validD);

        logD.enhance();


        return "success";
    }

}
